<?php 
/**
* filter class staffSelectionOutput
* type: output
* return: object
*/

class filterStaffSelectionOutput extends bookstoreOutputFilter{


	function __construct(){
		$this->type = 'output';
		$this->name = 'staffSelectionOutput';
	}//end constructor

	/**
	* reorganize db obj to emulate existing booksite term query
	* input is an db obj(returned from model->queryDb())
	*/
	
	function filter($return_type = '',&$input){
	
	//	foreach($input as $key=>$value){
		//	$object->result_set[$key]->sq1->reviews =& $this->getSelections($object->result_set[$key]->isbn);
			/*
			if(!empty($value)){
				$filtered_input->result_set[$key]->sq1->details[0] = $value;
				foreach($value as $k=>$v){
					$filtered_input->result_set[$key]->$k = $v;
				}//end of foreach in detail
				$filtered_input->result_set[$key]->sq1->instore->total_avail = $value->avail_for_sale;
			}else{ 
				
				$filtered_input->result_set[$key]->sq1->details[0] = $value;
				$results =new stdclass();
				$filtered_input->result_set[$key]->sq1->instore = new stdclass();
				$filtered_input->result_set[$key]->sq1->instore->flag = (string)'NIS';
				$filtered_input->result_set[$key]->sq1->instore->total_avail = (int)'0';
			}//end if results
		*/
		//	$filtered_input->result_set[$key] = $value;
		//	$filtered_input->result_set[$key]->sq1 = $results;
		}//end foreach
		
	//	return $filtered_input;
		return $input;
	}//end filter method
	
}//end filterStructOutput class

?>
